import { useRef } from "react";

export const useFangdou = (shijian) => {
  const item = useRef(null);
  item.current = setInterval(() => {
    clearInterval(item.current);
     shijian();
  }, 2000);
};
